package thread;

public class Demo4 {
    public static void main(String[] args) {
        Thread t = new Thread(new Runnable() {
            public void run() {
                while(true) {
                    System.out.println("匿名内部类针对Runnable!");
                    try {
                        Thread.sleep(100);
                    }catch (InterruptedException e) {
                        e.printStackTrace();
                    }
                }
                }
        });
        t.start();
    }
}
